import request from "@/utils/request"

export function findbypageG(data){
    return request({
        url: '/MallGoods/findByPage',
        method: 'post',
        data
    })
}
export function addG(data){
    return request({
        url: '/MallGoods/add',
        method: 'post',
        data
    })
}

export function deleteG(id){
    return request({
        url: '/MallGoods/delete',
        method: 'post',
        params:{id}
    })
}

export function updateG(data){
    return request({
        url: '/MallGoods/update',
        method: 'post',
        data
    })
}
export function findSpecAndOpts(templateId){
    return request({
        url: `/MallGoods/findSpecAndOpts/${templateId}`,
        method: 'get',
    })
}